<!DOCTYPE html>
<html lang="zh-CN">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1, user-scalable=no">
    <meta http-equiv="X-UA-Compatible" content="ie=edge,chrome=1">
    <meta name="author" content="杨宁争">
    <title></title>
    <style>
        * {
            box-sizing: border-box;
        }

        body {
            background-color: white;
        }

        #main {
            width: 410px;
            height: 514px;
            margin: 100px auto;
            background-color: white;
        }

        #big {
            width: 304px;
            height: 303px;
            display: inline-block;
            border: 1px solid blue;
            float: left;

            margin-top: 2px;

            background-size: 100%;
        }


        .small {
            width: 100px;
            height: 100px;
            display: inline-block;
            float: left;
            margin-top: 2px;
            margin-left: 2px;
        }
        img {
            width: 100%;
            height: 100%;
            border-radius: 10px;
        }
    </style>
</head>

<body>
    <div id="main">
        <div id="big">

        </div>



        <div class="small"><img src="big_1.jpg" alt=""></div>
        <div class="small"><img src="big_2.jpg" alt=""></div>
        <div class="small"><img src="big_3.jpg" alt=""></div>
        <div class="small"><img src="big_4.jpg" alt=""></div>
        <div class="small"><img src="big_5.jpg" alt=""></div>
        <div class="small"><img src="big_6.jpg" alt=""></div>
        <div class="small"><img src="big_7.jpg" alt=""></div>
        <div class="small"><img src="big_8.jpg" alt=""></div>
        <div class="small"><img src="big_9.jpg" alt=""></div>
        <div class="small"><img src="big_10.jpg" alt=""></div>
        <div class="small"><img src="big_11.jpg" alt=""></div>
    </div>
</body>

</html>
<script>
        var small=document.querySelectorAll('.small');
    var big=document.querySelector('#big');
    var img=document.querySelectorAll('img');

    var datu=document.querySelector('#datu');

    var arr=['url(big_1.jpg)','url(big_2.jpg)','url(big_3.jpg)','url(big_4.jpg)','url(big_5.jpg)','url(big_6.jpg)','url(big_7.jpg)',
    'url(big_8.jpg)','url(big_9.jpg)','url(big_10.jpg)','url(big_11.jpg)'];

    big.style.backgroundImage=arr[0];
    for(var i =0; i<img.length;i ++){
        img[i].index=i;
        img[i].onmouseenter=function(){
           
            big.style.backgroundImage=arr[this.index];
        }
    }
</script>